<% if defined? url %>
<%= link_to(img_tag(pic_cm),url,:target => "_blank") %>
<% elsif defined? avid %>
<%= link_to(img_tag(pic_cm),bili_video_path(avid),:target => "_blank") %>
<% elsif defined? mylistid %>
<%= link_to(img_tag(pic_cm),bili_mylist_path(mylistid),:target => "_blank") %>
<% else %>
<%= img_tag pic_cm %>
<% end %>